<template>
	<div class="container">
		<navigationBar title=" "></navigationBar>
		<div class="phoneLogin">
			<div class="title">手机号码登录</div>
			<div class="sub-title">未注册过的号码登录后将自动注册</div>
			<div class="main">
				<div class="warp">
					<div class="input"><input type="text" placeholder="请输入手机号" v-model="formData.phone" /></div>
				</div>
				<div class="warp" style="margin-bottom: 0;">
					<div class="input">
						<input type="text" password="true" placeholder="请输入验证码" v-model="formData.password" />
						<div class="get-code" v-if="num == 60" @click="getCode">{{getTxt}}
						</div>
						<div class="get-code" v-if="num !== 60">{{ num }}</div>
					</div>
				</div>
			</div>
			<!-- <div class="bottom">
				<span @click="toReset">忘记密码</span>
			</div> -->
			<div class="submit-btn" @click="submitForm">登录</div>
			<div class="radio-content">
				<Radio :isChecked="agree" @click.native="handlerChoose()"></Radio> <span class="read">已阅读并同意</span><span
					class="agreement" @click="toUserAgreement">《用户协议》</span>和<span class="agreement"
					@click="privacyAgreement">《隐私政策》</span>
			</div>
		</div>

	</div>
</template>

<script>
	import data from '@/js/publics/phoneLogin/data.js';
	import methods from '@/js/publics/phoneLogin/methods.js';
	import {
		mapState
	} from 'vuex';
	import navigationBar from '../../components/navigationBar.vue';
	import btn1 from '@/components/btn1.vue'
	import Radio from '@/components/radio.vue';
	export default {
		data,
		methods,
		onLoad() {
			// uni.getProvider({
			// 	service: 'oauth',
			// 	success: res => {
			// 		console.log('oauth: ', JSON.stringify(res))
			// 		if (res.provider) {
			// 			let provider = res.provider
			// 			this.provider = provider
			// 		}
			// 	}
			// })

		},
		onShow() {
			this.loading = false


		},
		onHide() {
			console.log('on hide')
		},
		onUnload() {

		},
		computed: {
			...mapState([
				'navigationBarHeight'
			])
		},
		components: {
			navigationBar,
			btn1,
			Radio
		}
	};
</script>
<style>
	page {
		background-color: #FFFFFF;
	}

	/* uni-page{
   	background-color: #FFFFFF;
   } */
</style>
<style scoped lang="scss">
	@import '~@/style/publics/phoneLogin.scss';

	.on {
		color: #999999 !important;
	}
</style>